<?
    include "../../php/common.php";
    $sql = "SELECT * FROM ptype";
    $res = mysqli_query($link,$sql);
    $arr = [] ;
    while( $one = mysqli_fetch_assoc($res) ){
        $arr[] = $one ; 
    }
    $str="";
    foreach( $arr as $key=>$value ){
        $str = $str."<option value='{$value["id"]}'>{$value['typename']}</option>";
    }
    echo $str ;
?>